package com.jdrx.sw.sewage.dao;

import com.jdrx.sw.sewage.beans.dto.EnergyReportQueryDTO;
import com.jdrx.sw.sewage.beans.dto.QualityReportQueryDTO;
import com.jdrx.sw.sewage.beans.dto.QualityReportsQueryDTO;
import com.jdrx.sw.sewage.beans.entity.StationReportPO;
import com.jdrx.sw.sewage.beans.vo.StationReportVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

@Mapper
public interface StationReportDAO {
    int deleteByPrimaryKey(Long id);

    int insert(StationReportPO record);

    StationReportVO selectByPrimaryKey(Long id);

    List<StationReportPO> selectAll();

    int updateByPrimaryKey(StationReportVO record);

    List<StationReportVO> selectEnergyReportList(EnergyReportQueryDTO energyReportQueryDTO);

    StationReportVO selectEnergyReport(@Param("queryTimeStr") String queryTimeStr,
                                       @Param("stationId") Long stationId,
                                       @Param("reportType") Integer reportType,
                                       @Param("dataNode") String dataNode);

    List<StationReportVO> selectQualityReportList(QualityReportQueryDTO qualityReportQueryDTO);

    int batchInsertHistory(Map<String, Object> params);

    int batchUpdateHistory(Map<String, Object> params);

    List<StationReportVO> selectStationsQualityReportList(QualityReportsQueryDTO qualityReportsQueryDTO);

    List<String> selectQualityTableHeadList(QualityReportQueryDTO qualityReportQueryDTO);
}